/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package onpu_dms_xls.exceptions;

/**
 *
 * @author snbm
 */
public class MySQLException extends MyException {

    private String query;
    private String inQueryParameters;

    public MySQLException(String className, String methodAndSectionName, String query, String inQueryParameters, String message) {
        super(className, methodAndSectionName, message);
        this.query = query;
        this.inQueryParameters = inQueryParameters;
    }

    @Override
    public String toString() {
        return "---SQL Exception:"
                + "\n--in class: " + className
                + "\n--in method/section: " + methodName
                + "\n--query: " + query
                + "\n--query parameters: " + inQueryParameters
                + "\n--with message: " + errorMessage;
    }
}
